package com.victor.dao2;

import java.util.List;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import com.victor.entity.YhUsers;

@Mapper
public interface UserDao {

	@Select({ "select * from yh_users" })
	List<YhUsers> getAllUser();

	@Select({ "select * from yh_users where phone=#{phone}" })
	YhUsers selYhuserByPhone(String phone);

	List<YhUsers> findByIds(@Param("ids") Integer[] ids);

	@Update("update yh_users set empiric_value = empiric_value + #{i} where user_id = #{userid}")
	int addExp(@Param("userid") String userid, @Param("i") int i);

	List<Integer> getAgeList(@Param("userid") String userid);

}
